//    Copyright (C) Kherty.  All rights reserved.
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Windows.Data;

namespace OpenLS.Spreadsheet.UI
{
    class TableStyleCellFactory: IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            var style = (TableStyle) value;
            var result = new List<TableStyleCell>();
            for (int i = 0; i < 5; i++)
                for (int j = 0; j < 5; j++)
                    result.Add(new TableStyleCell(style, i, j));
            return result;
        }

        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            throw new NotSupportedException();
        }
    }
}
